package ink.xiaobaibai.service;

import com.baomidou.mybatisplus.extension.service.IService;
import ink.xiaobaibai.bo.UserSelectBo;
import ink.xiaobaibai.entity.AdminUser;
import ink.xiaobaibai.vo.UserByAdminVo;

import java.util.List;

/**
 * <p>
 * 服务类
 * </p>
 *
 * @author xiaobaibai
 * @since 2021-05-11
 */
public interface IAdminUserService extends IService<AdminUser> {

    public Integer getDepId(Integer userId);

    public List<Integer> getUserIdByDepId(Integer depId);

    public int getUserVoByAdminCount(UserSelectBo userSelectBo);

    public List<UserByAdminVo> getUserVoByAdminList(UserSelectBo userSelectBo);

    public boolean existsUser(Integer userId);

    /**
     * 两人是否相同部门
     */
    public boolean identicalDep(Integer userId1, Integer userId2);

    /**
     * 查询当前角色部门内的所有用户id
     */
    public List<Integer> getDepUserIdByUserId(Integer userId);

    /**
     * 查询当前用户的角色
     */
    public List<String> getRoleListByUserId(Integer userId);

    /**
     * 查询经理们的信息
     */
    public List<AdminUser> getAgentUser();

    /**
     * 查询当前id的姓名+电话
     */
    public AdminUser getNameAndPhone(Integer id);

    /**
     * 当前管理者是否为供应商
     */
    public boolean isSupplierAdminUser(Integer userId);

    /**
     * 查询当前部门的经理的adminUserId
     */
    public AdminUser getAgentIdByDepId(Integer depId);

}
